package www.openteam.com.base;

import rx.Subscriber;
import www.openteam.com.exception.ApiException;

/**
 * Created by kylin on 2016/12/19.
 */

public  abstract class BaseSubscriber<T> extends Subscriber<T> {
    @Override
    public void onError(Throwable e) {
        ApiException apiException = (ApiException) e;
        onError(apiException);
    }

    /**
     *
     * @param apiException 错误的一个回调
     *
     */
    protected  abstract void onError(ApiException apiException);
}
